<template>
    <div id="dialog-container">
        <el-dialog v-dialogDrag 
            title="历史记录卡" append-to-body
            :visible.sync="dialogVisible" @close="$emit('update:show', false)" :before-close="handleClose" :show="show"
            :close-on-click-modal="false" width="700px">
            <el-table :data="tableData" size="small" border>
                <el-table-column type="index" label="序号" align="center" :resizable="false" width="50"></el-table-column>
                <el-table-column prop="" label="器具名称" :resizable="false" min-width="110"></el-table-column>
                <el-table-column prop="" label="存放地点" :resizable="false" min-width="120"></el-table-column>
                <el-table-column prop="" label="检定地点" :resizable="false" min-width="100"></el-table-column>
                <el-table-column prop="" label="生产厂家" :resizable="false" min-width="100"></el-table-column>
                <el-table-column prop="" label="测量范围" :resizable="false" min-width="80"></el-table-column>
                <el-table-column prop="" label="封存值" :resizable="false" min-width="60"></el-table-column>
                <el-table-column prop="" label="使用前级数" :resizable="false" min-width="130"></el-table-column>
                <el-table-column prop="" label="使用部门" :resizable="false" min-width="90"></el-table-column>
                <el-table-column prop="" label="附件" :resizable="false" min-width="90"></el-table-column>
                <el-table-column prop="" label="统一编号" :resizable="false" min-width="100"></el-table-column>
            </el-table>
            <div slot="footer" class="dialog-footer">
                <el-button type="primary" @click="dialogVisible = false">确 定</el-button>
                <el-button @click="dialogVisible = false">取 消</el-button>
            </div>
        </el-dialog>
    </div>
</template>

<script>
    export default {
        data() {
            return {
                dialogVisible: this.show,
                tableData: []
            }
        },
        props: {
            show: {
                type: Boolean,
                default: false
            }
        },
        watch: {
            show() {
                this.dialogVisible = this.show;
            }
        },
        methods: {
            handleClose() {
                this.dialogVisible = false;
            }
        }
    }
</script>